<template>
    <div class="wrapper">
        <swiper :options="swiperOption" >
			<swiper-slide class="swiper-img" v-for="item in list" :key="item.id">
                <img :src="item.imgUrl" alt=""  class="swiper-img">
            </swiper-slide>
			<!-- 这是轮播的小圆点 -->
			<div class="swiper-pagination" slot="pagination"></div>

		</swiper>
    </div>
    
</template>
<script>
export default {
    name:'HomeSwiper',
    props:{
        list:Array
    },
    data(){
        return{
            notNextTick: true,
            swiperOption:{
               paginationClickable: true,
               pagination:'.swiper-pagination',
            //    observer:true,//修改swiper自己或子元素时，自动初始化swiper 
            // 　　observeParents:true,//修改swiper的父元素时，自动初始化swiper 
            　　loop:true,
            　　autoplay:true,
                speed:1000,
                autoplayDisableOnInteraction: false,
                observer: true,
                observeParents: true,

            }
        }
    },
}
</script>
<style lang="stylus" scoped>
.wrapper >>> .swiper-pagination-bullet-active
    background :#fff !important
.wrapper
    width :100%
    height :0    
    overflow :hidden
    padding-bottom :32.25%
    background:#eee
    .swiper-img
        width:100%
</style>
